<html>
<head><meta charset="utf-8"><title>LLVMRust · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/LLVMRust.html">LLVMRust</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="243883490"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/LLVMRust/near/243883490" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Riccardo D&#x27;Ambrosio <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/LLVMRust.html#243883490">(Jun 25 2021 at 07:27)</a>:</h4>
<p>Hello!</p>
<p>While tinkering with the llvm codegen, i noticed that there are some special functions that start with <code>LLVMRust</code>, like <code>LLVMRustInstallFatalErrorHandler</code>. I couldnt find where these are located. Where can i find the source for these? are they some sort of llvm fork?</p>



<a name="243883618"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/LLVMRust/near/243883618" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Riccardo D&#x27;Ambrosio <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/LLVMRust.html#243883618">(Jun 25 2021 at 07:28)</a>:</h4>
<p>hmm actually spoke too soon, seems i found the source, although it seems weird that this is in C++ and not in special rust functions <span aria-label="thinking" class="emoji emoji-1f914" role="img" title="thinking">:thinking:</span></p>



<a name="243896202"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/LLVMRust/near/243896202" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> bjorn3 <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/LLVMRust.html#243896202">(Jun 25 2021 at 10:04)</a>:</h4>
<p>These functions exist because LLVM only exports a C++ api for this functionality and not a C api. Rust only has support for FFI through C and not through C++, so a C++ wrapper is necessary that exports a C interface.</p>



<a name="243960096"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/LLVMRust/near/243960096" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Riccardo D&#x27;Ambrosio <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/LLVMRust.html#243960096">(Jun 25 2021 at 19:30)</a>:</h4>
<p>Ah ok, thanks :)</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>